package com.ruoyi.purchase.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.purchase.mapper.InventoryManagementMapper;
import com.ruoyi.purchase.domain.InventoryManagement;
import com.ruoyi.purchase.service.IInventoryManagementService;

/**
 * 库存管理Service业务层处理
 * 
 * @author ruoyi
 * @date 2023-07-16
 */
@Service
public class InventoryManagementServiceImpl implements IInventoryManagementService 
{
    @Autowired
    private InventoryManagementMapper inventoryManagementMapper;

    /**
     * 查询库存管理
     * 
     * @param id 库存管理主键
     * @return 库存管理
     */
    @Override
    public InventoryManagement selectInventoryManagementById(Long id)
    {
        return inventoryManagementMapper.selectInventoryManagementById(id);
    }

    /**
     * 查询库存管理列表
     * 
     * @param inventoryManagement 库存管理
     * @return 库存管理
     */
    @Override
    public List<InventoryManagement> selectInventoryManagementList(InventoryManagement inventoryManagement)
    {
        return inventoryManagementMapper.selectInventoryManagementList(inventoryManagement);
    }

    /**
     * 新增库存管理
     * 
     * @param inventoryManagement 库存管理
     * @return 结果
     */
    @Override
    public int insertInventoryManagement(InventoryManagement inventoryManagement)
    {
        return inventoryManagementMapper.insertInventoryManagement(inventoryManagement);
    }

    /**
     * 修改库存管理
     * 
     * @param inventoryManagement 库存管理
     * @return 结果
     */
    @Override
    public int updateInventoryManagement(InventoryManagement inventoryManagement)
    {
        return inventoryManagementMapper.updateInventoryManagement(inventoryManagement);
    }

    /**
     * 批量删除库存管理
     * 
     * @param ids 需要删除的库存管理主键
     * @return 结果
     */
    @Override
    public int deleteInventoryManagementByIds(Long[] ids)
    {
        return inventoryManagementMapper.deleteInventoryManagementByIds(ids);
    }

    /**
     * 删除库存管理信息
     * 
     * @param id 库存管理主键
     * @return 结果
     */
    @Override
    public int deleteInventoryManagementById(Long id)
    {
        return inventoryManagementMapper.deleteInventoryManagementById(id);
    }
}
